package com.flower.system.service.impl;

import java.util.List;
import com.flower.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.flower.system.mapper.BizRecognitionMapper;
import com.flower.system.domain.BizRecognition;
import com.flower.system.service.IBizRecognitionService;

/**
 * 花卉识别结果Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-04-03
 */
@Service
public class BizRecognitionServiceImpl implements IBizRecognitionService 
{
    @Autowired
    private BizRecognitionMapper bizRecognitionMapper;

    /**
     * 查询花卉识别结果
     * 
     * @param id 花卉识别结果主键
     * @return 花卉识别结果
     */
    @Override
    public BizRecognition selectBizRecognitionById(String id)
    {
        return bizRecognitionMapper.selectBizRecognitionById(id);
    }

    /**
     * 查询花卉识别结果列表
     * 
     * @param bizRecognition 花卉识别结果
     * @return 花卉识别结果
     */
    @Override
    public List<BizRecognition> selectBizRecognitionList(BizRecognition bizRecognition)
    {
        return bizRecognitionMapper.selectBizRecognitionList(bizRecognition);
    }

    /**
     * 新增花卉识别结果
     * 
     * @param bizRecognition 花卉识别结果
     * @return 结果
     */
    @Override
    public int insertBizRecognition(BizRecognition bizRecognition)
    {
        bizRecognition.setCreateTime(DateUtils.getNowDate());
        return bizRecognitionMapper.insertBizRecognition(bizRecognition);
    }

    /**
     * 修改花卉识别结果
     * 
     * @param bizRecognition 花卉识别结果
     * @return 结果
     */
    @Override
    public int updateBizRecognition(BizRecognition bizRecognition)
    {
        bizRecognition.setUpdateTime(DateUtils.getNowDate());
        return bizRecognitionMapper.updateBizRecognition(bizRecognition);
    }

    /**
     * 批量删除花卉识别结果
     * 
     * @param ids 需要删除的花卉识别结果主键
     * @return 结果
     */
    @Override
    public int deleteBizRecognitionByIds(String[] ids)
    {
        return bizRecognitionMapper.deleteBizRecognitionByIds(ids);
    }

    /**
     * 删除花卉识别结果信息
     * 
     * @param id 花卉识别结果主键
     * @return 结果
     */
    @Override
    public int deleteBizRecognitionById(String id)
    {
        return bizRecognitionMapper.deleteBizRecognitionById(id);
    }
}
